package cn.net.yto.school.service.impl;

import cn.net.yto.school.dao.dto.CourseDownloadByCourseStsDto;
import cn.net.yto.school.dao.dto.CourseDownloadStsDto;
import cn.net.yto.school.dao.repositories.TbCourseRepository;
import cn.net.yto.school.service.StsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class StsServiceImpl implements StsService {

    @Autowired
    private TbCourseRepository courseRepository;

    @Override
    public List<CourseDownloadStsDto> stsCourseDownloadCount() {

        List<CourseDownloadStsDto> result = this.courseRepository.courseDownloadSts();

        return result;
    }

    @Override
    public List<CourseDownloadByCourseStsDto> courseDownloadByCourseSts() {

        List<CourseDownloadByCourseStsDto> result = this.courseRepository.courseDownloadByCourseSts();

        return result;
    }
}
